Skip to content

spec: fix ABNF grammar and add label normalization SHOULD#148

Open
0xheartcode wants to merge 2 commits intoremenoscodes:mainfrom
0xheartcode:spec/fix-abnf-grammar-and-label-normalization
Open

spec: fix ABNF grammar and add label normalization SHOULD#148
0xheartcode wants to merge 2 commits intoremenoscodes:mainfrom
0xheartcode:spec/fix-abnf-grammar-and-label-normalization

Conversation

@0xheartcode
Copy link
Copy Markdown

Two spec-only clarifications to ISSUE-FORMAT.md, no implementation changes required.

Changes

Fix ABNF grammar to use LF token (closes #130)

Section 4.8 defined CRLF = %x0A which contradicts RFC 5234 (where CRLF means %x0D.0A). Renamed the token to LF throughout the grammar to accurately reflect that Git commit messages use LF line endings. Also tightened title from TEXT-NO-LF to 1*TEXT-NO-LF to explicitly reject empty titles, and updated the 72-character guidance to use SHOULD per RFC 2119 convention.

Add RECOMMENDED label normalization (closes #133)

Added a SHOULD statement to Section 4.7 that implementations normalize labels to lowercase before comparison, to avoid case-variant duplicates like bug vs Bug. Marked as RECOMMENDED not REQUIRED to preserve intentional casing (e.g., iOS, API, UI). Referenced from Section 6.3.1 where the case-variant limitation is documented.

Test plan

  • Spec-only changes — no code modified, all 282 tests pass unchanged
  • make test: 282 passed, 0 failed

Section 4.8 defined CRLF = %x0A which contradicts RFC 5234. Renamed
to LF throughout the grammar. Also tightened title to 1*TEXT-NO-LF
to reject empty titles and updated the 72-char guidance to SHOULD.

Closes remenoscodes#130
Implementations SHOULD normalize labels to lowercase before comparison
to avoid case-variant duplicates. Not REQUIRED, to preserve intentional
casing like iOS, API, UI. Referenced in Section 6.3.1.

Closes remenoscodes#133
Copy link
Copy Markdown
Owner

@remenoscodes remenoscodes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ABNF fix (CRLF → LF) and the 1*TEXT-NO-LF tightening look correct — thank you for catching the RFC 5234 contradiction.

On the label normalization SHOULD: there's a tension with the existing normative text. Section 4.7 currently states "Labels are case-sensitive: Bug and bug are distinct labels" and the merge comparison says MUST compare "exactly (case-sensitive)." Adding a SHOULD to normalize to lowercase creates conflicting guidance — an implementor reading both statements can't satisfy them simultaneously.

Could you clarify the intended interaction? Options:

  1. Normalization applies at creation/edit time (deduplication), while merge comparison remains exact
  2. The case-sensitive statement gets softened to match
  3. Split into a separate PR so the uncontroversial ABNF fix can land first

Option 3 would also let us merge the ABNF fix immediately.

Copy link
Copy Markdown
Owner

@remenoscodes remenoscodes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Following up on the earlier review — the ABNF fix (CRLF → LF, 1*TEXT-NO-LF) is solid and I'd like to merge it soon.

To unblock that, could you split this into two PRs?

  1. PR A: ABNF grammar fix only (LF rename + title tightening) — ready to merge immediately
  2. PR B: Label normalization SHOULD — needs the normative conflict resolved first (see previous comment about the tension with the existing case-sensitive MUST)

This way the uncontroversial fix lands now, and we can iterate on the label normalization separately without blocking it.

Also, both commits should follow conventional commits format: spec: fix ABNF grammar to use LF token and spec: add RECOMMENDED label normalization.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add RECOMMENDED label normalization to spec Fix ABNF grammar: replace CRLF with LF token

2 participants